package edu.put.sk.nrpp;

import java.util.ArrayList;

import edu.put.sk.nrpp.ui.GraphicsConnection;

public class ConnectionList{

	public ArrayList<Connection> connections= new ArrayList<Connection>();
	public ArrayList<GraphicsConnection> graphicsConnections= new ArrayList<GraphicsConnection>();
	
	public void addConnection(Connection con){
		this.connections.add(con);
		GraphicsConnection gc = new GraphicsConnection(con);
		this.graphicsConnections.add(gc);
		con.linkGC(gc);
	}
	
	public void delConnection(Connection con){
		this.graphicsConnections.remove(con.graphicsConnection);
		this.connections.remove(con);
	}
}
